\hypertarget{classengine_1_1cSession}{\section{engine\-:\-:c\-Session Class Reference}
\label{classengine_1_1cSession}\index{engine\-::c\-Session@{engine\-::c\-Session}}
}


{\ttfamily \#include $<$session.\-h$>$}



Collaboration diagram for engine\-:\-:c\-Session\-:
\nopagebreak
\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[height=550pt]{classengine_1_1cSession__coll__graph}
\end{center}
\end{figure}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classengine_1_1cSession_ac84db9690073b0d7cd90b000b8c0e898}{{\bfseries c\-Session} (std\-::size\-\_\-t ses\-\_\-id)}\label{classengine_1_1cSession_ac84db9690073b0d7cd90b000b8c0e898}

\item 
void \hyperlink{classengine_1_1cSession_a35303640de423b2a94885d9f96c90f71}{Run\-Command} (std\-::shared\-\_\-ptr$<$ \hyperlink{classengine_1_1cCommand}{c\-Command} $>$ \&command)
\item 
void \hyperlink{classengine_1_1cSession_afe7cc1ff5b08117cc90d574e519bb08c}{Schedule\-Command} (std\-::shared\-\_\-ptr$<$ \hyperlink{classengine_1_1cCommand}{c\-Command} $>$ \&command)
\item 
\hypertarget{classengine_1_1cSession_a7827997872b114c09f4582a7ffcadb47}{std\-::shared\-\_\-ptr$<$ \hyperlink{classengine_1_1cCommand}{c\-Command} $>$ \& {\bfseries Get\-Pending\-Command} ()}\label{classengine_1_1cSession_a7827997872b114c09f4582a7ffcadb47}

\item 
void \hyperlink{classengine_1_1cSession_af1a1747cd7020bd4bfce782bf1ffec5d}{Terminate\-Command} ()
\item 
\hypertarget{classengine_1_1cSession_a4d5cfbd1a1a5d1ff022fd4915b256f4f}{int {\bfseries Get\-State} () const }\label{classengine_1_1cSession_a4d5cfbd1a1a5d1ff022fd4915b256f4f}

\item 
\hypertarget{classengine_1_1cSession_a922b139a6b22a63463403874e114ea1d}{void {\bfseries Set\-Pending\-Command} (std\-::shared\-\_\-ptr$<$ \hyperlink{classengine_1_1cCommand}{c\-Command} $>$ command)}\label{classengine_1_1cSession_a922b139a6b22a63463403874e114ea1d}

\end{DoxyCompactItemize}
\subsection*{Private Attributes}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classengine_1_1cSession_af7dc53c09799a31677b47a66ca5121ce}{std\-::size\-\_\-t {\bfseries m\-\_\-\-Session\-Id}}\label{classengine_1_1cSession_af7dc53c09799a31677b47a66ca5121ce}

\item 
\hypertarget{classengine_1_1cSession_af0edf0e0ced62ee7e8a5136637cc0084}{volatile int {\bfseries m\-\_\-\-State}}\label{classengine_1_1cSession_af0edf0e0ced62ee7e8a5136637cc0084}

\item 
\hypertarget{classengine_1_1cSession_ad880aa614d581b5155e75c22c775659b}{std\-::shared\-\_\-ptr$<$ \hyperlink{classengine_1_1cCommand}{c\-Command} $>$ {\bfseries m\-\_\-\-Pending\-Command}}\label{classengine_1_1cSession_ad880aa614d581b5155e75c22c775659b}

\end{DoxyCompactItemize}
\subsection*{Static Private Attributes}
\begin{DoxyCompactItemize}
\item 
\hypertarget{classengine_1_1cSession_a2f0a00f5302fdf8d88d4738c448ce4fa}{static \hyperlink{classengine_1_1cThreadPool}{c\-Thread\-Pool} {\bfseries s\-Thread\-Pool}}\label{classengine_1_1cSession_a2f0a00f5302fdf8d88d4738c448ce4fa}

\end{DoxyCompactItemize}


\subsection{Detailed Description}
implements a session for a client connected to the http\-\_\-server uses a thread pool to run received commands active object variant design pattern 

\subsection{Member Function Documentation}
\hypertarget{classengine_1_1cSession_a35303640de423b2a94885d9f96c90f71}{\index{engine\-::c\-Session@{engine\-::c\-Session}!Run\-Command@{Run\-Command}}
\index{Run\-Command@{Run\-Command}!engine::cSession@{engine\-::c\-Session}}
\subsubsection[{Run\-Command}]{\setlength{\rightskip}{0pt plus 5cm}void engine\-::c\-Session\-::\-Run\-Command (
\begin{DoxyParamCaption}
\item[{std\-::shared\-\_\-ptr$<$ {\bf c\-Command} $>$ \&}]{command}
\end{DoxyParamCaption}
)}}\label{classengine_1_1cSession_a35303640de423b2a94885d9f96c90f71}
runs a command and returns the result as soon as it finishes \hypertarget{classengine_1_1cSession_afe7cc1ff5b08117cc90d574e519bb08c}{\index{engine\-::c\-Session@{engine\-::c\-Session}!Schedule\-Command@{Schedule\-Command}}
\index{Schedule\-Command@{Schedule\-Command}!engine::cSession@{engine\-::c\-Session}}
\subsubsection[{Schedule\-Command}]{\setlength{\rightskip}{0pt plus 5cm}void engine\-::c\-Session\-::\-Schedule\-Command (
\begin{DoxyParamCaption}
\item[{std\-::shared\-\_\-ptr$<$ {\bf c\-Command} $>$ \&}]{command}
\end{DoxyParamCaption}
)}}\label{classengine_1_1cSession_afe7cc1ff5b08117cc90d574e519bb08c}
puts a command in the wait queue to be processed by the thread pool \hypertarget{classengine_1_1cSession_af1a1747cd7020bd4bfce782bf1ffec5d}{\index{engine\-::c\-Session@{engine\-::c\-Session}!Terminate\-Command@{Terminate\-Command}}
\index{Terminate\-Command@{Terminate\-Command}!engine::cSession@{engine\-::c\-Session}}
\subsubsection[{Terminate\-Command}]{\setlength{\rightskip}{0pt plus 5cm}void engine\-::c\-Session\-::\-Terminate\-Command (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}\label{classengine_1_1cSession_af1a1747cd7020bd4bfce782bf1ffec5d}
cancels a command received previously 

The documentation for this class was generated from the following files\-:\begin{DoxyCompactItemize}
\item 
session.\-h\item 
session.\-cpp\end{DoxyCompactItemize}
